package com.lq.ecoldchain.ui.order

import com.alibaba.android.arouter.facade.annotation.Autowired
import com.alibaba.android.arouter.facade.annotation.Route
import com.alibaba.android.arouter.launcher.ARouter
import com.lq.ecoldchain.R
import com.lq.ecoldchain.base.BaseNavigator
import com.lq.ecoldchain.base.view.BaseActivity
import com.lq.ecoldchain.databinding.ActivityPrepareOrderBinding
import org.kodein.di.Kodein
import org.kodein.di.generic.instance

/*
*2019/1/11 0011  16:23
*function by lq
*/
@Route(path = BaseNavigator.prepareOrder)
class PrepareOrderActivity : BaseActivity<ActivityPrepareOrderBinding>() {

    @JvmField
    @Autowired
    var orderId: String?=""

    override val layoutId = R.layout.activity_prepare_order
    override val viewDelegate: PrepareDelegate by instance()
    override fun initView() {
        ARouter.getInstance().inject(this)
        titleText("订单详情")
        binding.delegate = viewDelegate
        viewDelegate.viewModel.orderDetail(orderId!!.toInt())
    }

    override val kodein = Kodein.lazy {
        extend(parentKodein)
        import(prepareOderKodeinModule)
    }
}